package com.ljh.account.mapper;


import com.ljh.account.dao.Expense;
import com.ljh.account.dao.Resp.ExpenseResp;
import org.apache.ibatis.annotations.*;

import java.math.BigDecimal;
import java.util.List;

@Mapper
public interface ExpenseMapper {

    List<ExpenseResp> getExpensesWithFilter(@Param("userId") Long userId,
                                            @Param("categoryId") Integer categoryId,
                                            @Param("bankAccountId") Integer bankAccountId,
                                            @Param("minAmount") BigDecimal minAmount,
                                            @Param("maxAmount") BigDecimal maxAmount


    );

    ExpenseResp getExpenseById(int id);
    void insertExpense(Expense expense);
    void updateExpense(Expense expense);
    void deleteExpense(Long id);
}
